<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<div>
    <button onclick="fun('鲁')">按钮</button>
    <button onclick="fun(22)">按钮2</button>
</div>

<script>
    function fun(data){
        alert(data)
    }
</script>
</body>
</html>